.class final Lcom/wqmobile/sdk/protocol/i;
.super Landroid/os/Handler;


# instance fields
.field private synthetic a:Lcom/wqmobile/sdk/protocol/h;


# direct methods
.method constructor <init>(Lcom/wqmobile/sdk/protocol/h;)V
    .locals 0

    iput-object p1, p0, Lcom/wqmobile/sdk/protocol/i;->a:Lcom/wqmobile/sdk/protocol/h;

    invoke-direct {p0}, Landroid/os/Handler;-><init>()V

    return-void
.end method


# virtual methods
.method public final handleMessage(Landroid/os/Message;)V
    .locals 9

    const/4 v8, 0x1

    const/4 v7, 0x0

    :try_start_0
    iget-object v0, p0, Lcom/wqmobile/sdk/protocol/i;->a:Lcom/wqmobile/sdk/protocol/h;

    invoke-static {v0}, Lcom/wqmobile/sdk/protocol/h;->a(Lcom/wqmobile/sdk/protocol/h;)Lcom/wqmobile/sdk/protocol/d;

    move-result-object v0

    iget-object v0, v0, Lcom/wqmobile/sdk/protocol/d;->h:Lcom/wqmobile/sdk/protocol/b;

    sget-object v1, Lcom/wqmobile/sdk/protocol/b;->i:Lcom/wqmobile/sdk/protocol/b;

    if-ne v0, v1, :cond_0

    iget-object v0, p1, Landroid/os/Message;->obj:Ljava/lang/Object;

    check-cast v0, Lcom/wqmobile/sdk/protocol/g;

    invoke-virtual {v0}, Lcom/wqmobile/sdk/protocol/g;->b()Ljava/lang/String;

    move-result-object v1

    invoke-virtual {v0}, Lcom/wqmobile/sdk/protocol/g;->a()Lcom/wqmobile/sdk/protocol/cmd/c;

    move-result-object v2

    invoke-virtual {v0}, Lcom/wqmobile/sdk/protocol/g;->c()I

    move-result v0

    iget-object v3, p0, Lcom/wqmobile/sdk/protocol/i;->a:Lcom/wqmobile/sdk/protocol/h;

    invoke-static {v3}, Lcom/wqmobile/sdk/protocol/h;->a(Lcom/wqmobile/sdk/protocol/h;)Lcom/wqmobile/sdk/protocol/d;

    move-result-object v3

    invoke-virtual {v3}, Lcom/wqmobile/sdk/protocol/d;->m()Ljava/lang/Boolean;

    move-result-object v3

    invoke-virtual {v3}, Ljava/lang/Boolean;->booleanValue()Z

    move-result v3

    if-nez v3, :cond_6

    if-le v0, v8, :cond_6

    move-object v0, v1

    move-object v3, v2

    move v4, v7

    move v2, v7

    :goto_0
    if-gtz v4, :cond_1

    iget-object v0, p0, Lcom/wqmobile/sdk/protocol/i;->a:Lcom/wqmobile/sdk/protocol/h;

    invoke-static {v0}, Lcom/wqmobile/sdk/protocol/h;->a(Lcom/wqmobile/sdk/protocol/h;)Lcom/wqmobile/sdk/protocol/d;

    move-result-object v0

    sget-object v1, Lcom/wqmobile/sdk/protocol/b;->i:Lcom/wqmobile/sdk/protocol/b;

    iput-object v1, v0, Lcom/wqmobile/sdk/protocol/d;->h:Lcom/wqmobile/sdk/protocol/b;

    sget-object v0, Lcom/wqmobile/sdk/protocol/cmd/c;->f:Lcom/wqmobile/sdk/protocol/cmd/c;

    if-ne v3, v0, :cond_0

    iget-object v0, p0, Lcom/wqmobile/sdk/protocol/i;->a:Lcom/wqmobile/sdk/protocol/h;

    invoke-static {v0}, Lcom/wqmobile/sdk/protocol/h;->a(Lcom/wqmobile/sdk/protocol/h;)Lcom/wqmobile/sdk/protocol/d;

    move-result-object v0

    invoke-virtual {v0}, Lcom/wqmobile/sdk/protocol/d;->n()Landroid/content/Context;

    move-result-object v0

    invoke-static {v0}, Lcom/wqmobile/sdk/c/a;->a(Landroid/content/Context;)V

    :cond_0
    :goto_1
    return-void

    :cond_1
    iget-object v5, p0, Lcom/wqmobile/sdk/protocol/i;->a:Lcom/wqmobile/sdk/protocol/h;

    invoke-static {v5}, Lcom/wqmobile/sdk/protocol/h;->a(Lcom/wqmobile/sdk/protocol/h;)Lcom/wqmobile/sdk/protocol/d;

    move-result-object v5

    sget-object v6, Lcom/wqmobile/sdk/protocol/b;->g:Lcom/wqmobile/sdk/protocol/b;

    iput-object v6, v5, Lcom/wqmobile/sdk/protocol/d;->h:Lcom/wqmobile/sdk/protocol/b;

    iget-object v5, p0, Lcom/wqmobile/sdk/protocol/i;->a:Lcom/wqmobile/sdk/protocol/h;

    invoke-static {v5}, Lcom/wqmobile/sdk/protocol/h;->a(Lcom/wqmobile/sdk/protocol/h;)Lcom/wqmobile/sdk/protocol/d;

    move-result-object v5

    iget-object v5, v5, Lcom/wqmobile/sdk/protocol/d;->b:Lcom/wqmobile/sdk/protocol/cmd/WQTransferData;

    invoke-virtual {v5}, Lcom/wqmobile/sdk/protocol/cmd/WQTransferData;->g()V

    if-eqz v2, :cond_3

    sget-object v5, Lcom/wqmobile/sdk/protocol/cmd/c;->e:Lcom/wqmobile/sdk/protocol/cmd/c;

    if-ne v3, v5, :cond_3

    sget-object v2, Lcom/wqmobile/sdk/protocol/cmd/c;->f:Lcom/wqmobile/sdk/protocol/cmd/c;

    :goto_2
    iget-object v5, p0, Lcom/wqmobile/sdk/protocol/i;->a:Lcom/wqmobile/sdk/protocol/h;

    invoke-static {v5}, Lcom/wqmobile/sdk/protocol/h;->a(Lcom/wqmobile/sdk/protocol/h;)Lcom/wqmobile/sdk/protocol/d;

    move-result-object v5

    new-instance v6, Lcom/wqmobile/sdk/protocol/a/a;

    invoke-direct {v6}, Lcom/wqmobile/sdk/protocol/a/a;-><init>()V

    iput-object v6, v5, Lcom/wqmobile/sdk/protocol/d;->i:Lcom/wqmobile/sdk/protocol/a/a;

    invoke-static {v2, v0}, Lcom/wqmobile/sdk/protocol/g;->a(Lcom/wqmobile/sdk/protocol/cmd/c;Ljava/lang/String;)Lcom/wqmobile/sdk/protocol/cmd/WQCommandContent;

    move-result-object v0

    iget-object v2, p0, Lcom/wqmobile/sdk/protocol/i;->a:Lcom/wqmobile/sdk/protocol/h;

    invoke-static {v2}, Lcom/wqmobile/sdk/protocol/h;->a(Lcom/wqmobile/sdk/protocol/h;)Lcom/wqmobile/sdk/protocol/d;

    move-result-object v2

    iget-object v2, v2, Lcom/wqmobile/sdk/protocol/d;->i:Lcom/wqmobile/sdk/protocol/a/a;

    monitor-enter v2
    :try_end_0
    .catch Ljava/lang/Exception; {:try_start_0 .. :try_end_0} :catch_0

    :try_start_1
    iget-object v5, p0, Lcom/wqmobile/sdk/protocol/i;->a:Lcom/wqmobile/sdk/protocol/h;

    invoke-static {v5}, Lcom/wqmobile/sdk/protocol/h;->a(Lcom/wqmobile/sdk/protocol/h;)Lcom/wqmobile/sdk/protocol/d;

    move-result-object v5

    invoke-virtual {v5}, Lcom/wqmobile/sdk/protocol/d;->c()V

    iget-object v5, p0, Lcom/wqmobile/sdk/protocol/i;->a:Lcom/wqmobile/sdk/protocol/h;

    invoke-static {v5}, Lcom/wqmobile/sdk/protocol/h;->a(Lcom/wqmobile/sdk/protocol/h;)Lcom/wqmobile/sdk/protocol/d;

    move-result-object v5

    invoke-virtual {v5, v0}, Lcom/wqmobile/sdk/protocol/d;->a(Lcom/wqmobile/sdk/protocol/cmd/a;)V

    iget-object v0, p0, Lcom/wqmobile/sdk/protocol/i;->a:Lcom/wqmobile/sdk/protocol/h;

    invoke-static {v0}, Lcom/wqmobile/sdk/protocol/h;->a(Lcom/wqmobile/sdk/protocol/h;)Lcom/wqmobile/sdk/protocol/d;

    move-result-object v0

    iget-object v0, v0, Lcom/wqmobile/sdk/protocol/d;->i:Lcom/wqmobile/sdk/protocol/a/a;

    const-wide/16 v5, 0x6d60

    invoke-virtual {v0, v5, v6}, Ljava/lang/Object;->wait(J)V

    iget-object v0, p0, Lcom/wqmobile/sdk/protocol/i;->a:Lcom/wqmobile/sdk/protocol/h;

    invoke-static {v0}, Lcom/wqmobile/sdk/protocol/h;->a(Lcom/wqmobile/sdk/protocol/h;)Lcom/wqmobile/sdk/protocol/d;

    move-result-object v0

    iget-object v0, v0, Lcom/wqmobile/sdk/protocol/d;->i:Lcom/wqmobile/sdk/protocol/a/a;

    invoke-virtual {v0}, Lcom/wqmobile/sdk/protocol/a/a;->k()Z

    move-result v0

    if-nez v0, :cond_5

    iget-object v0, p0, Lcom/wqmobile/sdk/protocol/i;->a:Lcom/wqmobile/sdk/protocol/h;

    invoke-static {v0}, Lcom/wqmobile/sdk/protocol/h;->a(Lcom/wqmobile/sdk/protocol/h;)Lcom/wqmobile/sdk/protocol/d;

    move-result-object v0

    iget-object v0, v0, Lcom/wqmobile/sdk/protocol/d;->i:Lcom/wqmobile/sdk/protocol/a/a;

    invoke-virtual {v0}, Lcom/wqmobile/sdk/protocol/a/a;->p()Z

    move-result v0

    if-nez v0, :cond_2

    iget-object v0, p0, Lcom/wqmobile/sdk/protocol/i;->a:Lcom/wqmobile/sdk/protocol/h;

    invoke-static {v0}, Lcom/wqmobile/sdk/protocol/h;->a(Lcom/wqmobile/sdk/protocol/h;)Lcom/wqmobile/sdk/protocol/d;

    move-result-object v0

    invoke-static {v0}, Lcom/wqmobile/sdk/protocol/d;->b(Lcom/wqmobile/sdk/protocol/d;)Lcom/wqmobile/sdk/protocol/c;

    move-result-object v0

    iget-object v5, p0, Lcom/wqmobile/sdk/protocol/i;->a:Lcom/wqmobile/sdk/protocol/h;

    invoke-static {v5}, Lcom/wqmobile/sdk/protocol/h;->a(Lcom/wqmobile/sdk/protocol/h;)Lcom/wqmobile/sdk/protocol/d;

    move-result-object v5

    iget-object v5, v5, Lcom/wqmobile/sdk/protocol/d;->i:Lcom/wqmobile/sdk/protocol/a/a;

    invoke-virtual {v0, v5}, Lcom/wqmobile/sdk/protocol/c;->a(Lcom/wqmobile/sdk/protocol/a/a;)V

    :cond_2
    add-int/lit8 v0, v4, -0x1

    move-object v4, v3

    move v5, v0

    move-object v0, v1

    move v3, v8

    :goto_3
    iget-object v6, p0, Lcom/wqmobile/sdk/protocol/i;->a:Lcom/wqmobile/sdk/protocol/h;

    invoke-static {v6}, Lcom/wqmobile/sdk/protocol/h;->a(Lcom/wqmobile/sdk/protocol/h;)Lcom/wqmobile/sdk/protocol/d;

    move-result-object v6

    invoke-virtual {v6}, Lcom/wqmobile/sdk/protocol/d;->g()V

    monitor-exit v2
    :try_end_1
    .catchall {:try_start_1 .. :try_end_1} :catchall_0

    move v2, v3

    move-object v3, v4

    move v4, v5

    goto/16 :goto_0

    :cond_3
    if-nez v2, :cond_4

    :try_start_2
    sget-object v2, Lcom/wqmobile/sdk/protocol/cmd/c;->e:Lcom/wqmobile/sdk/protocol/cmd/c;

    if-ne v3, v2, :cond_4

    iget-object v2, p0, Lcom/wqmobile/sdk/protocol/i;->a:Lcom/wqmobile/sdk/protocol/h;

    invoke-static {v2}, Lcom/wqmobile/sdk/protocol/h;->a(Lcom/wqmobile/sdk/protocol/h;)Lcom/wqmobile/sdk/protocol/d;

    move-result-object v2

    sget-object v5, Lcom/wqmobile/sdk/protocol/b;->f:Lcom/wqmobile/sdk/protocol/b;

    iput-object v5, v2, Lcom/wqmobile/sdk/protocol/d;->h:Lcom/wqmobile/sdk/protocol/b;

    iget-object v2, p0, Lcom/wqmobile/sdk/protocol/i;->a:Lcom/wqmobile/sdk/protocol/h;

    invoke-static {v2}, Lcom/wqmobile/sdk/protocol/h;->a(Lcom/wqmobile/sdk/protocol/h;)Lcom/wqmobile/sdk/protocol/d;

    move-result-object v2

    invoke-static {v2}, Lcom/wqmobile/sdk/protocol/d;->a(Lcom/wqmobile/sdk/protocol/d;)Ljava/lang/String;

    move-result-object v2

    invoke-virtual {v2}, Ljava/lang/String;->trim()Ljava/lang/String;

    move-result-object v2

    invoke-virtual {v2}, Ljava/lang/String;->length()I

    move-result v2

    if-nez v2, :cond_4

    iget-object v2, p0, Lcom/wqmobile/sdk/protocol/i;->a:Lcom/wqmobile/sdk/protocol/h;

    invoke-static {v2}, Lcom/wqmobile/sdk/protocol/h;->a(Lcom/wqmobile/sdk/protocol/h;)Lcom/wqmobile/sdk/protocol/d;

    move-result-object v2

    invoke-static {v2, v1}, Lcom/wqmobile/sdk/protocol/d;->a(Lcom/wqmobile/sdk/protocol/d;Ljava/lang/String;)V
    :try_end_2
    .catch Ljava/lang/Exception; {:try_start_2 .. :try_end_2} :catch_0

    :cond_4
    move-object v2, v3

    goto/16 :goto_2

    :cond_5
    :try_start_3
    iget-object v0, p0, Lcom/wqmobile/sdk/protocol/i;->a:Lcom/wqmobile/sdk/protocol/h;

    invoke-static {v0}, Lcom/wqmobile/sdk/protocol/h;->a(Lcom/wqmobile/sdk/protocol/h;)Lcom/wqmobile/sdk/protocol/d;

    move-result-object v0

    invoke-static {v0}, Lcom/wqmobile/sdk/protocol/d;->a(Lcom/wqmobile/sdk/protocol/d;)Ljava/lang/String;

    move-result-object v0

    sget-object v3, Lcom/wqmobile/sdk/protocol/cmd/c;->e:Lcom/wqmobile/sdk/protocol/cmd/c;
    :try_end_3
    .catchall {:try_start_3 .. :try_end_3} :catchall_0

    move v5, v4

    move-object v4, v3

    move v3, v7

    goto :goto_3

    :catchall_0
    move-exception v0

    :try_start_4
    monitor-exit v2

    throw v0
    :try_end_4
    .catch Ljava/lang/Exception; {:try_start_4 .. :try_end_4} :catch_0

    :catch_0
    move-exception v0

    invoke-static {v0}, Lcom/wqmobile/sdk/protocol/cmd/b;->a(Ljava/lang/Exception;)V

    goto/16 :goto_1

    :cond_6
    move-object v3, v2

    move v4, v0

    move-object v0, v1

    move v2, v7

    goto/16 :goto_0
.end method
